home *** CD-ROM | disk | FTP | other *** search
- import java.io.DataInputStream;
-
- public class CVariableRect {
- private CVarOrValue m_vvLeft = new CVarOrValue();
- private CVarOrValue m_vvRight = new CVarOrValue();
- private CVarOrValue m_vvTop = new CVarOrValue();
- private CVarOrValue m_vvBottom = new CVarOrValue();
-
- void LoadFromFile(DataInputStream var1) {
- this.m_vvLeft.LoadFromFile(var1);
- this.m_vvTop.LoadFromFile(var1);
- this.m_vvRight.LoadFromFile(var1);
- this.m_vvBottom.LoadFromFile(var1);
- }
-
- CRect GetRect() {
- CRect var1 = new CRect(this.m_vvLeft.GetValue(), this.m_vvTop.GetValue(), this.m_vvRight.GetValue() - this.m_vvLeft.GetValue(), this.m_vvBottom.GetValue() - this.m_vvTop.GetValue());
- return var1;
- }
-
- void setToRectangle(CRect var1) {
- this.m_vvLeft.SetValue(var1.x);
- this.m_vvTop.SetValue(var1.y);
- this.m_vvRight.SetValue(var1.x + var1.width);
- this.m_vvBottom.SetValue(var1.y + var1.height);
- }
- }
-